package com.yenlien.traceyun.business.entity;

import com.yenlien.traceyun.webase.entity.BaseIdEntity;
import io.swagger.annotations.ApiModelProperty;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Transient;
import java.util.Date;

/**
 * @author: bigwangy@sina.com
 * @create: 2020-12-15
 * @description:召回
 **/

@Entity(name = "t_recall")
public class Recall extends BaseIdEntity {



    @ApiModelProperty(value = "召回范围", example = "一号果园")
    @Column(name = "`range`")
    private String range;


    @ApiModelProperty(value = "产品图片, 多个使用 ; 分割", example = "A.png")
    private String prodImg;


    @ApiModelProperty(value = "创建时间")
    private String createTime;




    /**
     * 召回产品
     */
    @Column(name = "product_name", length = 30)
    private String productName;

    /**
     * 召回批次
     */
    @Column(name = "batch_no", length = 30)
    private String batchNo;

    /**
     * 召回流程,主分支
     */
    @Column(name = "trace_Step", length = 30)
    private String traceStep;

    /**
     * 召回时间
     */
    @Column(name = "recall_date")
    private Date recallDate;

    /**
     * 召回原因
     */
    @Column(columnDefinition = "longtext")
    private String reason;

    /**
     * 公司id
     */
    @Column(name = "company_id", length = 32)
    private String companyId;

    @Column(name = "company_name", length = 100)
    private String companyName;

    /**
     * 召回人
     */
    @Column(name = "username", length = 20)
    private String username;

    /**
     * 应用id
     */
    @Column(name = "app_id", length = 32)
    private String appId;



    @Transient
    private String pageType;
    @Transient
    private Integer pageNum;





    public String getRange() {
        return range;
    }

    public void setRange(String range) {
        this.range = range;
    }

    public String getProdImg() {
        return prodImg;
    }

    public void setProdImg(String prodImg) {
        this.prodImg = prodImg;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime;
    }

    public String getPageType() {
        return pageType;
    }

    public void setPageType(String pageType) {
        this.pageType = pageType;
    }

    public Integer getPageNum() {
        return pageNum;
    }

    public void setPageNum(Integer pageNum) {
        this.pageNum = pageNum;
    }

    public String getProductName() {
        return productName;
    }

    public void setProductName(String productName) {
        this.productName = productName;
    }

    public String getBatchNo() {
        return batchNo;
    }

    public void setBatchNo(String batchNo) {
        this.batchNo = batchNo;
    }

    public String getTraceStep() {
        return traceStep;
    }

    public void setTraceStep(String traceStep) {
        this.traceStep = traceStep;
    }

    public Date getRecallDate() {
        return recallDate;
    }

    public void setRecallDate(Date recallDate) {
        this.recallDate = recallDate;
    }

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public String getCompanyId() {
        return companyId;
    }

    public void setCompanyId(String companyId) {
        this.companyId = companyId;
    }

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getCompanyName() {
        return companyName;
    }

    public void setCompanyName(String companyName) {
        this.companyName = companyName;
    }

    @Override
    public String toString() {
        return "Recall{" +
                "productName='" + productName + '\'' +
                ", batchNo='" + batchNo + '\'' +
                ", traceStep='" + traceStep + '\'' +
                ", recallDate=" + recallDate +
                ", reason='" + reason + '\'' +
                ", companyId='" + companyId + '\'' +
                ", appId='" + appId + '\'' +
                '}';
    }
}
